<?xml version="1.0" encoding="ascii"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
          "DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <title>pytils.templatetags.pytils_dt</title>
  <link rel="stylesheet" href="epydoc.css" type="text/css" />
  <script type="text/javascript" src="epydoc.js"></script>
</head>

<body bgcolor="white" text="black" link="blue" vlink="#204080"
      alink="#204080">
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">
  <!-- Home link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="pytils-module.html">Home</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

      <th class="navbar" width="100%"></th>
  </tr>
</table>
<table width="100%" cellpadding="0" cellspacing="0">
  <tr valign="top">
    <td width="100%">
      <span class="breadcrumbs">
        <a href="pytils-module.html">Package&nbsp;pytils</a> ::
        <a href="pytils.templatetags-module.html">Package&nbsp;templatetags</a> ::
        Module&nbsp;pytils_dt
      </span>
    </td>
    <td>
      <table cellpadding="0" cellspacing="0">
        <!-- hide/show private -->
        <tr><td align="right"><span class="options">[<a href="javascript: void(0);" class="privatelink"
    onclick="toggle_private();">hide private</a>]</span></td></tr>
        <tr><td align="right"><span class="options"
            >[<a href="frames.html" target="_top">frames</a
            >]&nbsp;|&nbsp;<a href="pytils.templatetags.pytils_dt-module.html"
            target="_top">no&nbsp;frames</a>]</span></td></tr>
      </table>
    </td>
  </tr>
</table>
<!-- ==================== MODULE DESCRIPTION ==================== -->
<h1 class="epydoc">Module pytils_dt</h1><span class="codelink"><a href="pytils.templatetags.pytils_dt-pysrc.html">source&nbsp;code</a></span><br /><br />
pytils.dt templatetags for Django web-framework<br /><br />

<!-- ==================== FUNCTIONS ==================== -->
<a name="section-Functions"></a>
<table class="summary" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Functions</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-Functions"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
<tr>
  <td width="15%" align="right" valign="top" class="summary">
    <code class="summary-type">&nbsp;</code>
  </td><td class="summary">
    <span class="summary-sig"><a href="pytils.templatetags.pytils_dt-module.html#distance_of_time" class="summary-sig-name">distance_of_time</a>(<span class="summary-sig-arg">from_time</span>,
        <span class="summary-sig-arg">accuracy</span>=<span class="summary-sig-default">1</span>)</span><br />
      Display distance of time from current time.
  </td>
</tr>
<tr>
  <td width="15%" align="right" valign="top" class="summary">
    <code class="summary-type">&nbsp;</code>
  </td><td class="summary">
    <span class="summary-sig"><a href="pytils.templatetags.pytils_dt-module.html#ru_strftime" class="summary-sig-name">ru_strftime</a>(<span class="summary-sig-arg">date</span>,
        <span class="summary-sig-arg">format</span>=<span class="summary-sig-default">&quot;%d.%m.%Y&quot;</span>,
        <span class="summary-sig-arg">inflected_day</span>=<span class="summary-sig-default">False</span>)</span><br />
      Russian strftime, formats date with given format.
  </td>
</tr>
<tr>
  <td width="15%" align="right" valign="top" class="summary">
    <code class="summary-type">&nbsp;</code>
  </td><td class="summary">
    <span class="summary-sig"><a href="pytils.templatetags.pytils_dt-module.html#ru_strftime_inflected" class="summary-sig-name">ru_strftime_inflected</a>(<span class="summary-sig-arg">date</span>,
        <span class="summary-sig-arg">format</span>=<span class="summary-sig-default">&quot;%d.%m.%Y&quot;</span>,
        <span class="summary-sig-arg">inflected_day</span>=<span class="summary-sig-default">True</span>)</span><br />
      Russian strftime with inflected day, formats date with given 
      format (similar to ru_strftime), also inflects day in proper 
      form.
  </td>
</tr>
</table>

<br />
<!-- ==================== VARIABLES ==================== -->
<a name="section-Variables"></a>
<table class="summary" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Variables</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-Variables"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
<tr>
  <td width="15%" align="right" valign="top" class="summary">
    <code class="summary-type">&nbsp;</code>
  </td><td class="summary">
    <a href="pytils.templatetags.pytils_dt-module.html#__revision__">__revision__</a> = <code title="'$Id: pytils_dt.py 29 2006-10-21 08:28:27Z the.pythy $'">'$Id: pytils_dt.py 29 2006-10-21 08:28:27Z the.pythy $'</code>
  </td>
</tr>
<tr>
  <td width="15%" align="right" valign="top" class="summary">
    <code class="summary-type">&nbsp;</code>
  </td><td class="summary">
    <a href="pytils.templatetags.pytils_dt-module.html#__id__">__id__</a> = <code title="'$Id: pytils_dt.py 29 2006-10-21 08:28:27Z the.pythy $'">'$Id: pytils_dt.py 29 2006-10-21 08:28:27Z the.pythy $'</code>
  </td>
</tr>
<tr>
  <td width="15%" align="right" valign="top" class="summary">
    <code class="summary-type">&nbsp;</code>
  </td><td class="summary">
    <a href="pytils.templatetags.pytils_dt-module.html#__url__">__url__</a> = <code title="'$URL: https://pythy.googlecode.com/svn/trunk/pytils/pytils/templatetags/pytils_dt.py $'">'$URL: https://pythy.googlecode.com/svn/trunk/pytils...</code>
  </td>
</tr>
<tr>
  <td width="15%" align="right" valign="top" class="summary">
    <code class="summary-type">&nbsp;</code>
  </td><td class="summary">
    <a href="pytils.templatetags.pytils_dt-module.html#register">register</a> = <code title="&lt;django.template.Library object at 0xb7aad6ec&gt;">&lt;django.template.Library object at 0xb7aad6ec&gt;</code><br />
      Django template tag/filter registrator
  </td>
</tr>
<tr>
  <td width="15%" align="right" valign="top" class="summary">
    <code class="summary-type">&nbsp;</code>
  </td><td class="summary">
    <a href="pytils.templatetags.pytils_dt-module.html#encoding">encoding</a> = <code title="'utf-8'">'utf-8'</code><br />
      Current charset (sets in Django project's settings)
  </td>
</tr>
<tr>
  <td width="15%" align="right" valign="top" class="summary">
    <code class="summary-type">&nbsp;</code>
  </td><td class="summary">
    <a href="pytils.templatetags.pytils_dt-module.html#debug">debug</a> = <code title="True">True</code><br />
      Debug mode (sets in Django project's settings)
  </td>
</tr>
<tr>
  <td width="15%" align="right" valign="top" class="summary">
    <code class="summary-type">&nbsp;</code>
  </td><td class="summary">
    <a href="pytils.templatetags.pytils_dt-module.html#show_value">show_value</a> = <code title="False">False</code><br />
      Show values on errors (sets in Django project's settings)
  </td>
</tr>
<tr>
  <td width="15%" align="right" valign="top" class="summary">
    <code class="summary-type">&nbsp;</code>
  </td><td class="summary">
    <a href="pytils.templatetags.pytils_dt-module.html#default_value">default_value</a> = <code title="'unknown: %(error)s'">'unknown: %(error)s'</code>
  </td>
</tr>
<tr>
  <td width="15%" align="right" valign="top" class="summary">
    <code class="summary-type">&nbsp;</code>
  </td><td class="summary">
    <a href="pytils.templatetags.pytils_dt-module.html#default_uvalue">default_uvalue</a> = <code title="u'unknown: %(error)s'">u'unknown: %(error)s'</code>
  </td>
</tr>
</table>

<br />
<!-- ==================== FUNCTION DETAILS ==================== -->
<a name="section-FunctionDetails"></a>
<table class="summary" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Function Details</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-FunctionDetails"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
</table>
<a name="distance_of_time"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">distance_of_time</span>(<span class="sig-arg">from_time</span>,
        <span class="sig-arg">accuracy</span>=<span class="sig-default">1</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pytils.templatetags.pytils_dt-pysrc.html#distance_of_time">source&nbsp;code</a></span>&nbsp;</span
    ></td>
  </table>
  
  <p>Display distance of time from current time.</p>
  <p>Parameter is an accuracy level (deafult is 1). Value must be numeral 
  (i.e. time.time() result) or datetime.datetime (i.e. 
  datetime.datetime.now() result).</p>
  Examples:
<pre class="literalblock">
   {{ some_time|distance_of_time }}
   {{ some_dtime|distance_of_time:2 }}
</pre>
  <dl><dt></dt><dd>
  </dd></dl>
</td></tr></table>
</div>
<a name="ru_strftime"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">ru_strftime</span>(<span class="sig-arg">date</span>,
        <span class="sig-arg">format</span>=<span class="sig-default">&quot;%d.%m.%Y&quot;</span>,
        <span class="sig-arg">inflected_day</span>=<span class="sig-default">False</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pytils.templatetags.pytils_dt-pysrc.html#ru_strftime">source&nbsp;code</a></span>&nbsp;</span
    ></td>
  </table>
  
  <p>Russian strftime, formats date with given format.</p>
  <p>Value is a date (supports datetime.date and datetime.datetime), 
  parameter is a format (string). For explainings about format, see 
  documentation for original strftime: 
  http://docs.python.org/lib/module-time.html</p>
  Examples:
<pre class="literalblock">
   {{ some_date|ru_strftime:&quot;%d %B %Y, %A&quot; }}
</pre>
  <dl><dt></dt><dd>
  </dd></dl>
</td></tr></table>
</div>
<a name="ru_strftime_inflected"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">ru_strftime_inflected</span>(<span class="sig-arg">date</span>,
        <span class="sig-arg">format</span>=<span class="sig-default">&quot;%d.%m.%Y&quot;</span>,
        <span class="sig-arg">inflected_day</span>=<span class="sig-default">True</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pytils.templatetags.pytils_dt-pysrc.html#ru_strftime_inflected">source&nbsp;code</a></span>&nbsp;</span
    ></td>
  </table>
  
  <p>Russian strftime with inflected day, formats date with given format 
  (similar to ru_strftime), also inflects day in proper form.</p>
  Examples:
<pre class="literalblock">
   {{ some_date|ru_strftime_inflected:&quot;in %A (%d %B %Y)&quot;
</pre>
  <dl><dt></dt><dd>
  </dd></dl>
</td></tr></table>
</div>
<br />
<!-- ==================== VARIABLES DETAILS ==================== -->
<a name="section-VariablesDetails"></a>
<table class="summary" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Variables Details</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-VariablesDetails"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
</table>
<a name="__revision__"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <h3 class="epydoc">__revision__</h3>
  None
  <dl><dt></dt><dd>
    <dl><dt>Value:</dt>
      <dd><table><tr><td><pre class="variable">
<span class="variable-quote">'</span>$Id: pytils_dt.py 29 2006-10-21 08:28:27Z the.pythy $<span class="variable-quote">'</span>                
      </pre></td></tr></table></dd>
    </dl>
  </dd></dl>
</td></tr></table>
</div>
<a name="__id__"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <h3 class="epydoc">__id__</h3>
  None
  <dl><dt></dt><dd>
    <dl><dt>Value:</dt>
      <dd><table><tr><td><pre class="variable">
<span class="variable-quote">'</span>$Id: pytils_dt.py 29 2006-10-21 08:28:27Z the.pythy $<span class="variable-quote">'</span>                
      </pre></td></tr></table></dd>
    </dl>
  </dd></dl>
</td></tr></table>
</div>
<a name="__url__"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <h3 class="epydoc">__url__</h3>
  None
  <dl><dt></dt><dd>
    <dl><dt>Value:</dt>
      <dd><table><tr><td><pre class="variable">
<span class="variable-quote">'</span>$URL: https://pythy.googlecode.com/svn/trunk/pytils/pytils/templateta<span class="variable-linewrap"><img src="crarr.png" alt="" /></span>
gs/pytils_dt.py $<span class="variable-quote">'</span>                                                     
      </pre></td></tr></table></dd>
    </dl>
  </dd></dl>
</td></tr></table>
</div>
<a name="register"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <h3 class="epydoc">register</h3>
  Django template tag/filter registrator
  <dl><dt></dt><dd>
    <dl><dt>Value:</dt>
      <dd><table><tr><td><pre class="variable">
&lt;django.template.Library object at 0xb7aad6ec&gt;                         
      </pre></td></tr></table></dd>
    </dl>
  </dd></dl>
</td></tr></table>
</div>
<a name="encoding"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <h3 class="epydoc">encoding</h3>
  Current charset (sets in Django project's settings)
  <dl><dt></dt><dd>
    <dl><dt>Value:</dt>
      <dd><table><tr><td><pre class="variable">
<span class="variable-quote">'</span>utf-8<span class="variable-quote">'</span>                                                                
      </pre></td></tr></table></dd>
    </dl>
  </dd></dl>
</td></tr></table>
</div>
<a name="debug"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <h3 class="epydoc">debug</h3>
  Debug mode (sets in Django project's settings)
  <dl><dt></dt><dd>
    <dl><dt>Value:</dt>
      <dd><table><tr><td><pre class="variable">
True                                                                   
      </pre></td></tr></table></dd>
    </dl>
  </dd></dl>
</td></tr></table>
</div>
<a name="show_value"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <h3 class="epydoc">show_value</h3>
  Show values on errors (sets in Django project's settings)
  <dl><dt></dt><dd>
    <dl><dt>Value:</dt>
      <dd><table><tr><td><pre class="variable">
False                                                                  
      </pre></td></tr></table></dd>
    </dl>
  </dd></dl>
</td></tr></table>
</div>
<a name="default_value"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <h3 class="epydoc">default_value</h3>
  None
  <dl><dt></dt><dd>
    <dl><dt>Value:</dt>
      <dd><table><tr><td><pre class="variable">
<span class="variable-quote">'</span>unknown: %(error)s<span class="variable-quote">'</span>                                                   
      </pre></td></tr></table></dd>
    </dl>
  </dd></dl>
</td></tr></table>
</div>
<a name="default_uvalue"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <h3 class="epydoc">default_uvalue</h3>
  None
  <dl><dt></dt><dd>
    <dl><dt>Value:</dt>
      <dd><table><tr><td><pre class="variable">
u'unknown: %(error)s'                                                  
      </pre></td></tr></table></dd>
    </dl>
  </dd></dl>
</td></tr></table>
</div>
<br />
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">
  <!-- Home link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="pytils-module.html">Home</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

      <th class="navbar" width="100%"></th>
  </tr>
</table>
<table border="0" cellpadding="0" cellspacing="0" width="100%%">
  <tr>
    <td align="left" class="footer">Generated by Epydoc
        3.0alpha3 on Sun Oct 29 00:35:02 2006</td>
    <td align="right" class="footer">
      <a href="http://epydoc.sourceforge.net">http://epydoc.sourceforge.net</a>
    </td>
  </tr>
</table>

<script type="text/javascript">
  <!--
  // Private objects are initially displayed (because if
  // javascript is turned off then we want them to be
  // visible); but by default, we want to hide them.  So hide
  // them unless we have a cookie that says to show them.
  checkCookie()
  // -->
</script>
  
</body>
</html>
